<form class="editForm" action="${saveUrl}" method="post" responseType="JSON" role="form" id="editForm_${serializeNum}" 
	data-bv-submitButtons="#editFormSubmitBtn_${serializeNum}"
	data-bv-message="This value is not valid"
	data-bv-feedbackicons-valid="glyphicon glyphicon-ok"
	data-bv-feedbackicons-invalid="glyphicon glyphicon-remove"
	data-bv-feedbackicons-validating="glyphicon glyphicon-refresh">
	<input type="hidden" name="formKey" value="${formKey}">
	<input type="hidden" name="formToken" value="${formToken}">
	<div class="modal-header">
		<button type="button" class="close" data-dismiss="modal"
			aria-hidden="true">×</button>
		<h4 class="modal-title" id="dialog">${(editModel=='add')?string('新增','编辑')}</h4>
	</div>
	<div class="modal-body">
		 <div class="row">
			<input type="hidden" name="id" value="${editEntity.id}">
		 	<#if (true && editModel=='add')||(true && editModel=='edit')>
			<div class="form-group">
				<label for="sysId" class="col-sm-2 control-label no-padding-right">权限名称</label>
				<div class="col-sm-10">
					<select  name="sysId" class="selectpicker_${serializeNum}" data-live-search="true">
						<optgroup label="选择所属分组" data-icon="icon-ok">
							<option value="">无</option>
							<#list sysId_datasources as datasources >
								<option value="${datasources.id}">${datasources.name}</option>
							</#list>
						</optgroup>
					</select>
					<script type="text/javascript">
						$("[name='sysId']").val("${editEntity.sysId}");
					</script>
				</div>
			</div>
			</#if>
			<#if (true && editModel=='add')||(true && editModel=='edit')>
			<div class="form-group">
				<label for="name" class="col-sm-2 control-label no-padding-right"></label>
				<div class="col-sm-10">
					<input  data-bv-message="The field is not valid"maxlength="100" name="name" id="name" type="text" class="form-control"  value="${editEntity.name}" />
                    <span class="text"></span>
				</div>
			</div>
			</#if>
			<#if (true && editModel=='add')||(true && editModel=='edit')>
			<div class="form-group">
				<label for="weight" class="col-sm-2 control-label no-padding-right">权重</label>
				<div class="col-sm-10">
					<input   data-bv-integer-message="The field is number" data-bv-message="The field is not valid" data-bv-integer="true"maxlength="11" name="weight" alt="权重" id="weight" placeholder="权重" type="text" title="权重" class="form-control"  value="${editEntity.weight}" />
                    <span class="text"></span>
				</div>
			</div>
			</#if>
			<#if (true && editModel=='add')||(true && editModel=='edit')>
			<div class="form-group">
				<label for="isForbidden" class="col-sm-2 control-label no-padding-right">是否禁用</label>
				<div class="col-sm-10">
					<input type="hidden" name="isForbidden" value="${editEntity.isForbidden}">
                   	<label>
                       <input  data-target-input-name="isForbidden" data-bv-message="The field is not valid"maxlength="1" alt="是否禁用" id="isForbidden" placeholder="是否禁用" type="checkbox" title="是否禁用" class="form-control checkbox-slider slider-icon yesno"   ${(editEntity.isForbidden???string(editEntity.isForbidden?string('checked',''),''))!''}>
                       <span class="text"></span>
                   	</label>
				</div>
			</div>
			</#if>
			<#if (false && editModel=='add')||(false && editModel=='edit')>
			<div class="form-group">
				<label for="createTime" class="col-sm-2 control-label no-padding-right">创建时间</label>
				<div class="col-sm-10">
					<span class="input-icon icon-left">
                        <input data-bv-date-format="YYYY-MM-DD hh:mm:ss" data-bv-message="The field is not valid" data-bv-date-message="请正确输入一个时间" data-bv-date="true"maxlength="19" name="createTime" alt="创建时间" id="createTime" placeholder="创建时间" type="text" title="创建时间" class="form-control form-control date-picker" onfocus="WdatePicker({doubleCalendar:true,dateFmt:'yyyy-MM-dd HH:mm:ss'})"  value="${editEntity.createTime}"/>
                        <i class="fa fa-calendar"></i>
                    </span>
				</div>
			</div>
			</#if>
			<#if (false && editModel=='add')||(false && editModel=='edit')>
			<div class="form-group">
				<label for="createUserId" class="col-sm-2 control-label no-padding-right">创建人Id</label>
				<div class="col-sm-10">
					<input  data-bv-message="The field is not valid"maxlength="32" name="createUserId" alt="创建人Id" id="createUserId" placeholder="创建人Id" type="text" title="创建人Id" class="form-control"  value="${editEntity.createUserId}" />
                    <span class="text"></span>
				</div>
			</div>
			</#if>
			<#if (false && editModel=='add')||(false && editModel=='edit')>
			<div class="form-group">
				<label for="version" class="col-sm-2 control-label no-padding-right"></label>
				<div class="col-sm-10">
					<input   data-bv-integer-message="The field is number" data-bv-message="The field is not valid" data-bv-integer="true"maxlength="11" name="version" id="version" type="text" class="form-control"  value="${editEntity.version}" />
                    <span class="text"></span>
				</div>
			</div>
			</#if>
		</div>
	</div>
	<div class="modal-footer">
		<div class="form-group">
			<div class="col-sm-offset-5 col-sm-7">
				<input type="button" class="btn btn-default" data-dismiss="modal" value="取消"/>
				<button type="submit" class="btn btn-blue" id="editFormSubmitBtn_${serializeNum}">保存</button>
			</div>
		</div>
	</div>
</form>
<script src="assets/js/validation/bootstrapValidator_init.js"></script>
<script>
$(".selectpicker_${serializeNum}").select2();
</script>